package com.whjfxx.terminal.biz.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.whjfxx.terminal.biz.param.SearchParam;
import com.whjfxx.terminal.biz.param.TerminalPageParam;
import com.whjfxx.terminal.entity.PoTerminal;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.time.LocalDateTime;

/**
 * Created by b.c on 2022/4/14 10:22
 */
@Repository
public interface PoTerminalMapper extends BaseMapper<PoTerminal> {

    /**
     * 删除
     * @param id
     * @param deleteTime
     */
    void logicDelete(@Param("id") Long id, @Param("deleteTime") LocalDateTime deleteTime);

    /**
     *
     * @param id
     * @param localAddress
     */
    void setlocalAddress(@Param("id") Long id,@Param("localAddress") String localAddress);


    PoTerminal listBySnAndFuncName(@Param("sn") String sn,@Param("funcName") String funcName);

    IPage<PoTerminal> page(SearchParam searchParam, TerminalPageParam pageParam);
}
